<!DOCTYPE html><html><head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <meta name="format-detection" content="telephone=no">
	<title>【<?php echo $output['memberhome']['nickname'];?>】的快乐拍宝</title>
	<link href="<?php echo TEMPLATE_SITE_URL;?>/css/common.css" type="text/css" rel="stylesheet">
	<link href="<?php echo TEMPLATE_SITE_URL;?>/css/info.css" type="text/css" rel="stylesheet">
	<script type="text/javascript" src="<?php echo RESOURCE_SITE_URL;?>/js/zepto.js" charset="utf-8"></script>	
<style>
.shield{ width:100%;height:100%;  background:url(<?php echo TEMPLATE_SITE_URL;?>/images/shield1.png);position:fixed;z-index:9999;}
	  .shieldDiv{width:100%;background:#fff;/*实现IE背景透明*/position:fixed; bottom:0;}
	  .shildBn {color:#555;width:100%;height:35px;line-height:35px;display:block;border-top:#ddd 1px solid;text-align:center;}
	  .shildBn:hover {text-decoration:none;}
</style>
</head>
<body>
         <div class="shield" style="display: none;">
           <div class="shieldDiv">
           	  <?php if(!empty($output['pingbi'])){?>
           	  <a class="shildBn" pingbi="0">取消屏蔽该用户</a>               
              <?php }else{?>
              <a class="shildBn" style="color:#eb5153;" pingbi="1">屏蔽该用户</a>   
              <?php }?>                      
              <script>
				$(function(){
					$('.shildBn').click(function(){
						var pingbiid = '<?php echo $output['memberhome']['user_id'];?>';
						var pingbi = $(this).attr('pingbi');
						$.ajax({
							type:'get',
							url:'index.php?act=my&op=pingbi',
							data:{pingbiid:pingbiid,pingbi:pingbi},
							dataType:'json',
							success:function(){
								alert('操作成功');
								location.reload();
							}	
						});
					});;
				});
              </script>
			  <a class="shildBn2" href="index.php?act=my&op=pingbiview">查看屏蔽用户</a>
              <a class="shildBn1 cancel1" style="border-top:#ddd 5px solid;">取消</a>
           </div>
        </div>
<div id="contentbox">
    <div class="userContainer">
        <div class="avatarBox">
            <div class="avatar" style="background-image: url(<?php echo $output['memberhome']['avatar'];?>)"></div>
        </div>
        	<div class="name"><?php echo $output['memberhome']['nickname'];?></div>
        	<div class="shopToolsBanner">
                <div class="tool view">浏览店铺</div>
                <div class="tool url">店铺链接</div>
                <div class="tool qrcode" onclick="javascript:location.href='<?php echo BASE_SITE_URL;?>/index.php?act=my&op=qrcode&seller_id=<?php echo intval($_GET['uid']);?>'">二 维 码</div>       
            </div>
        </div>
    <div class="userRateContainer">
 
        <div class="menuItemBanner">
            <div class="menuItem seller selected">
                卖家<span class="level l<?php echo strtolower($output['memberhome']['slevel'])?>"></span>
                <div class="scores">积分：<?php echo $output['memberhome']['spoints'];?></div>
            </div>
            <div class="menuItem buyer">
                买家<span class="level l<?php echo strtolower($output['memberhome']['ulevel'])?>"></span>
                <div class="scores">积分：<?php echo $output['memberhome']['upoints'];?></div>
            </div>
        </div>

        <div class="userRateBox">
            <div class="userRateList seller">
            	<div class="sellerTrangle"></div>
                <div class="userRate">拍品评分<br><?php echo $output['seller_pingfen']?>分</div>
                <div class="userRate">违约比例<br><?php echo $output['seller_weiyue']*100?>%</div>
            </div>
            <div class="userRateList buyer" style="display: none;">
            	<div class="userTrangle"></div>
                <div class="userRate">退货比例<br><?php echo $output['user_tuihuo']*100?>%</div>
                <div class="userRate">违约比例<br><?php echo $output['user_weiyue']*100?>%</div>
            </div>
        </div>
        
        <script type="text/javascript">
			$(function(){
				$('.menuItemBanner .seller').click(function(){
					$(this).addClass('selected');
					$('.userRateBox .seller').show();

					$('.menuItemBanner .buyer').removeClass('selected');
					$('.userRateBox .buyer').hide();
				});

				$('.menuItemBanner .buyer').click(function(){
					$(this).addClass('selected');					
					$('.userRateBox .buyer').show();

					$('.menuItemBanner .seller').removeClass('selected');
					$('.userRateBox .seller').hide();
				});		
			});
        </script>        
    </div>
	
    
    <div class="userInfobox"> 
	<?php 
	if($output['memberhome']['xinyu']!=0){
		?>
		<div style='color:red;'>消保金已缴纳：<?php echo $output['memberhome']['xinyu'];?>元</div>
		<?php
	}
	?>
	
    		<?php if($output['memberhome']['is_company']==1){?>
    		<div class="identify">
    			<span class="identifyTitle">实名认证</span>  
    			<span class="identifyIcon"><em><?php if($output['memberhome']['is_company_type']==1){ echo '企业认证';}else{ echo '个人认证';}?></em>
    			<?php if($output['memberhome']['is_company_type']==1){?>
    			<img src="<?php echo TEMPLATE_SITE_URL;?>/images/blue_certify.png" width="25" height="16">
    			<?php }else{?>
    			<img src="<?php echo TEMPLATE_SITE_URL;?>/images/certify.png" width="25" height="16">
    			<?php }?>
    			</span>
    			<span class="identifyStata">已由<?php echo $output['site_name']?>官方审核</span>
    		</div>
    		<?php }?>
	       	<div class="userInfoitem sales">
	            <a href="index.php?act=shop&seller_id=<?php echo intval($_GET['uid']);?>">
	            <div class="title">最近拍品</div>
	            <div class="info">
	            <?php if(!empty($output['auction'])){?>
	            <?php $pic = 0;?>
	            <?php foreach($output['auction'] as $val){?>
	            <?php if($pic>2)break;?>
	            <div class="img" style="background-image: url(<?php echo UPLOAD_SITE_URL.'/shop/auction/'.$val['auction_add_date'].'/'.$val['auction_img1'];?>);"></div>
	            <?php $pic++;?>
	            <?php }?>
	            <?php }?>
	            </div>
	            <div class="editArrow"></div>
	            </a>
	        </div>
	            <div class="userInfoitem">
	                <div class="title">地区</div>
	                <div class="info"><?php echo $output['memberhome']['province'];?>&nbsp;<?php echo $output['memberhome']['city'];?></div>
	                <?php if(!empty($_COOKIE['user_id']) && $_COOKIE['user_id']==$_GET['uid']){?>
                    <a href="index.php?act=payment&op=addresslist">
                    <div class="editArrow"></div>
                    </a>
                    <?php }?>
                </div>
                <?php if(($output['is_show']==1)||($_COOKIE['user_id']==$_GET['uid'])){?>
	                <div class="userInfoitem">
	                	<div class="title">手机号码</div>
	                    <a href="tel:<?php echo $output['memberhome']['mobile'];?>">
	                        <div class="info"><?php echo $output['memberhome']['mobile'];?></div>
	                    </a>                   
	                    <?php if(!empty($_COOKIE['user_id']) && $_COOKIE['user_id']==$_GET['uid']){?>
	                    <a href="index.php?act=my&op=editinfo&type=mobile">
	                    <div class="editArrow"></div>
	                    </a>
	                    <?php }?>
	                </div>
			    <?php }?>
			    
			    <div class="userInfoitem">
	                <div class="title">个性签名</div>
	                <div class="info">
						<?php if(!empty($output['memberhome']['signature'])){ echo $output['memberhome']['signature']; }else{ echo '主人什么都没有留下';}?>
					</div>
	                <?php if(!empty($_COOKIE['user_id']) && $_COOKIE['user_id']==$_GET['uid']){?>
	                <a href="index.php?act=my&op=editinfo&type=signature"><div class="editArrow"></div></a>
	                <?php }?>
	            </div>
			   <?php if($output['guanzhu']==1){?>
               <div class="userInfoitem">
                	<div class="title">联系人</div>
                    <a href="javascript:;"><div class="info"><?php echo $output['memberhome']['contract'];?></div></a>                   
                    <?php if(!empty($_COOKIE['user_id']) && $_COOKIE['user_id']==$_GET['uid']){?>
                    <a href="index.php?act=my&op=editinfo&type=contract"><div class="editArrow"></div></a>
                    <?php }?>
               </div>
  
               <div class="userInfoitem">
                	<div class="title">微信号</div>
                    <a href="javascript:;">
                        <div class="info"><?php echo $output['memberhome']['wxaccount'];?></div>
                    </a>                   
                    <?php if(!empty($_COOKIE['user_id']) && $_COOKIE['user_id']==$_GET['uid']){?>
                    <a href="index.php?act=my&op=editinfo&type=wxaccount">
                    	<div class="editArrow"></div>
                    </a>
                    <?php }?>
               </div>
               <?php }?>		    
    		</div>
    		<?php if($_GET['uid']!=$_COOKIE['user_id']){?>
    		<?php if($output['guanzhu']==1){?>
    		<button class="cancle">取消关注</button>
        	<?php }else{?>
        	<button class="submit">关注</button>
        	<?php }?>              	 	
            <div class="userMenu pingbi"></div>
            <?php }?>
        </div>     
        

        
        
<script type="text/javascript">
$(function(){

	$('.url').click(function(){
		var seller_id = '<?php echo intval($_GET['uid']);?>';
		$.ajax({
			type:'get',
			url:'index.php?act=my&op=sendaddr',
			data:{seller_id:seller_id},
			dataType:'json',
			success:function(data){
				if(data.state=='1'){
					alert('已发送至公众号');
				}
				return false;
			}
		});
	});
	
	$('.view').click(function(){
		location.href = '<?php echo BASE_SITE_URL;?>/index.php?act=shop&seller_id='+<?php echo intval($_GET['uid']);?>;
	});
	
	$('.cancle').click(function(){
		var uid = '<?php echo $_COOKIE['user_id'];?>';
		var fid = '<?php echo intval($_GET['uid']);?>';

		$.ajax({
			type:'get',
			url:'index.php?act=my&op=cancelguanzhu',
			data:{uid:uid,fid:fid},
			dataType:'json',
			success:function(data){
				if(data.state){
					location.reload();
				}
				return false;
			}
		});
	});

	$('.cancel1').click(function(){
		$('.shield').hide();
		return false;
	});
	
	$('.pingbi').click(function(){
		$('.shield').show();
		return false;
		
		var pingbi = '<?php echo $output['pingbi']['pingbi'];?>';

		if(pingbi=='1'){
			if(confirm('确认取消屏蔽?')){
				var seller_id = '<?php echo $output['memberhome']['user_id'];?>';
				$.ajax({
					type:'get',
					url:'index.php?act=my&op=pingbi',
					data:{seller_id:seller_id,pingbi:pingbi},
					dataType:'json',
					success:function(){
						location.reload();
					}	
				});
			}
		}else{
			if(confirm('确认屏蔽?')){
				var seller_id = '<?php echo $output['memberhome']['user_id'];?>';
				$.ajax({
					type:'get',
					url:'index.php?act=my&op=pingbi',
					data:{seller_id:seller_id,pingbi:pingbi},
					dataType:'json',
					success:function(){
						location.reload();
					}	
				});
			}
		}
		

	});
	
	$('.submit').click(function(){
		var uid = '<?php echo $_COOKIE['user_id'];?>';
		var fid = '<?php echo intval($_GET['uid']);?>';

		$.ajax({
			type:'get',
			url:'index.php?act=my&op=guanzhu',
			data:{uid:uid,fid:fid},
			dataType:'json',
			success:function(data){
				if(data.state){
					location.reload();
				}
				return false;
			}
		});	
	});
});
</script>        
<?php include template('home/nav');?>
</body>
</html>